// Learn cc.Class:
//  - https://docs.cocos.com/creator/manual/en/scripting/class.html
// Learn Attribute:
//  - https://docs.cocos.com/creator/manual/en/scripting/reference/attributes.html
// Learn life-cycle callbacks:
//  - https://docs.cocos.com/creator/manual/en/scripting/life-cycle-callbacks.html
material.id = 9;
cc.Class({
    extends: cc.Component,

    properties: {
       
    },

    // LIFE-CYCLE CALLBACKS:

    // onLoad () {},
    showShop(){
        let tmp = cc.find('Canvas/show/market/marketAlert');
        // cc.log(tmp)
        tmp.active = true;
    },
    start () {

    },
    buy(target,id){
        //点击进货
        cc.log(target.target.parent.id)
        material.id = target.target.parent.id;
        material = {
            id:target.target.parent.id
        }
    }
    // update (dt) {},
});
